<%--
  Created by IntelliJ IDEA.
  User: WuLiangHang
  Date: 2021/12/20
  Time: 14:10
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>Title</title>
</head>
<body>
<%
    /*
    request.getScheme() //获取请求协议
    request.getServerName()//获取服务器IP地址或者域名
    request.getServerPort()//获取服务器端口号
    request.getContextPath()//获取工程路径
    request.getMethod()//获取请求方法
    request.getRemoteHost()//获取客户端IP地址
    request.getSession().getId()//获取Session对象的ID
     */
%>
0.获取请求对象${pageContext.request}<br/>
1.获取协议:${pageContext.request.scheme}<br/>
2.获取服务器IP地址:${pageContext.request.serverName}<br/>
3.获取服务器端口号:${pageContext.request.serverPort}<br/>
4.获取工程路径:${pageContext.request.contextPath}<br/>
5.获取请求方法:${pageContext.request.method}<br/>
6.获取客户端IP地址:${pageContext.request.remoteHost}<br/>
7.获取Session对象的ID:${pageContext.request.session.id}<br/>
8.获取Session对象的ID:${pageContext.request.requestedSessionId}<br/>
9.获取Cookie值:${cookie.JSESSIONID.value}<br/>
</body>
</html>
